package chpt04.two;

import chpt04.one.Base;

public class Child extends Base{
	/*可访问Base类中声明为protected的属性和方法*/
	public void test() {
		i = 5;
		changeI(10);
		System.out.println(super.i);
	}
	
	@Override
	public void show() {
		super.show();
		System.out.println("Child's show!");
	}

	public static void main(String[] args) {
		Child c = new Child();
		c.test();
		c.show();
		Base e = new Child();
		//e.show();//无法访问声明为protected
	}

}
